Skip to content

fix(schemas): stop design.md from restating the proposal#1401

Merged
clay-good merged 3 commits into
mainfrom
fix/design-proposal-boundary
Jul 22, 2026
Merged

fix(schemas): stop design.md from restating the proposal#1401
clay-good merged 3 commits into
mainfrom
fix/design-proposal-boundary

Conversation

@clay-good

@clay-good clay-good commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

Status: Ready for review. Guidance-only change to the default spec-driven schema - no code paths, no CLI behavior, no schema structure changes.

What was wrong: #1382 - in the default schema, proposal.md and design.md often end up saying the same thing. The design instruction asked for "Background, current state, constraints, stakeholders" and "What this design achieves and excludes" without ever saying that motivation and scope already live in the proposal, so agents dutifully restated the proposal's Why and What Changes instead of adding the design's differentiated value (approach, alternatives, trade-offs). The proposal side already had its boundary line ("implementation details belong in design.md"); the design side had no equivalent.

How it was fixed: Two files, wording only:

  • schemas/spec-driven/schema.yaml (design instruction): Context is scoped to "only the current state and constraints needed to explain the approach," with a cross-reference example ("See proposal.md - Why"); Goals / Non-Goals now says not to restate the proposal's scope; the closing guidance states the boundary explicitly - the proposal covers why and what, design covers how; reference rather than restate.
  • schemas/spec-driven/templates/design.md: section comments mirror the same boundary, and the Decisions comment now mentions alternatives considered.

The third acceptance criterion in #1382 (alternatives and trade-offs as first-class decision content) was already met by the existing instruction ("Include alternatives considered for each decision") - this PR only surfaces it in the template comment.

Proof it works: schemas/ ships verbatim in the npm package and is parsed at runtime, so there are no compiled copies or golden hashes to regenerate (same shape as #1326 and #1366). Verified:

Notes: Deliberately does not touch the proposal instruction (its boundary line already exists, and #1399 currently has open edits in that section). Design/architecture untouched - this clarifies the schema's existing intent (the instruction already said "Reference the proposal for motivation").

Closes #1382

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Documentation
    • Updated spec-driven design guidance to improve “Context” framing, clarify explicit scope boundaries, and more clearly separate responsibilities between the proposal (“why/what”) and the design (“how”).
    • Revised the design markdown template placeholders to better direct authors to reuse proposal details and include prompts to record “alternatives considered.”

The spec-driven design instruction asked for background, current state,
and goals without saying the motivation and scope already live in
proposal.md, so generated designs often duplicated the proposal instead
of adding technical decisions. Scope the Context and Goals guidance to
what the approach needs, and state the boundary explicitly: the proposal
covers why and what, design covers how - reference, don't restate.

Closes #1382

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@clay-good
clay-good requested a review from TabishB as a code owner July 20, 2026 21:36
@coderabbitai

coderabbitai Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 50eff99c-a5a6-4d0d-a3da-17ccc3630232

📥 Commits

Reviewing files that changed from the base of the PR and between ddc8de8 and 7d396d8.

📒 Files selected for processing (1)
  • .changeset/design-proposal-boundary.md

📝 Walkthrough

Walkthrough

The spec-driven schema now distinguishes proposal responsibilities from design responsibilities, limits duplicated context, and clarifies design decision guidance. The design template references proposal.md, includes alternatives considered, and adds a patch changeset.

Changes

Proposal and design guidance

Layer / File(s) Summary
Schema and template guidance
schemas/spec-driven/schema.yaml, schemas/spec-driven/templates/design.md, .changeset/design-proposal-boundary.md
Clarifies proposal “why/what” versus design “how”, directs authors to reference existing proposal and specification content, updates design placeholders, and records a patch release.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

Suggested reviewers: tabishb

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: preventing design.md from repeating proposal content.
Linked Issues check ✅ Passed The schema and template updates explicitly separate proposal and design roles, discourage repetition, and require alternatives and trade-offs.
Out of Scope Changes check ✅ Passed The added changeset is in scope and supports the same documentation guidance update.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/design-proposal-boundary

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@schemas/spec-driven/schema.yaml`:
- Around line 129-131: Align the guidance with the design dependency by updating
the design requirements near the proposal/specs instructions to include specs in
design.requires, ensuring specs exist before design generation. Preserve the
existing proposal dependency and avoid changing unrelated documentation.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 9d5c7bf3-79f7-4813-9856-42deefe78c8e

📥 Commits

Reviewing files that changed from the base of the PR and between 60f720c and 15bd1b4.

📒 Files selected for processing (2)
  • schemas/spec-driven/schema.yaml
  • schemas/spec-driven/templates/design.md

Comment thread schemas/spec-driven/schema.yaml Outdated
design.requires is [proposal] only, so a design can be drafted before
the specs exist. Say "once written" instead of implying the specs are
always there to reference.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@alfred-openspec alfred-openspec left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The proposal/design boundary is now explicit without changing the existing parallel artifact ordering, and the template mirrors the schema guidance. Exact-head build plus 96 focused schema, resolver, and instruction-loader tests passed.

…ndary

schemas/ ships in the npm package files list, so this guidance change
reaches users on upgrade and needs a changelog entry. The Validate
Release Tracking check only validates changesets when present, so its
absence was not caught.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@alfred-openspec alfred-openspec left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The added patch changeset accurately captures the user-visible schema guidance change, and its parent is the previously reviewed head. Full exact-head CI is green; approval restored.

@clay-good
clay-good added this pull request to the merge queue Jul 22, 2026
Merged via the queue into main with commit b33b15d Jul 22, 2026
14 checks passed
@clay-good
clay-good deleted the fix/design-proposal-boundary branch July 22, 2026 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clarify proposal/design boundaries to reduce duplicated planning artifacts

2 participants